#include "Pthread.hpp"

int main()
{
    ThreadModule::Thread t([](){
        while(true)
        {
            std::cout << "hello world" << std::endl;
            sleep(1);
        }
    });
    t.Start();
    std::cout << t.Name() << " is Running! " << std::endl;
    sleep(4);
    t.Stop();
    std::cout << "Stop thread : " << t.Name() << std::endl;
    sleep(1);
    t.Join();
    std::cout << "Join thread : " << t.Name() << std::endl;
    return 0;
}